package com.txc.pay.alipayLife.controller;


import com.txc.openfeign.common.pay.vo.QueryCollectResVO;
import com.txc.openfeign.common.pay.vo.ResBaseVO;
import com.txc.openfeign.common.pay.vo.ResponseCodeEnum;
import com.txc.openfeign.common.pay.vo.UserCostInfoVO;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * 测试生活缴费
 *
 * @ClassName: TestAlipayLifeController
 * @Author: TXC
 * @Date: 2023-01-23 10:03
 **/
@RestController
@RequestMapping("/test")
public class TestAlipayLifeController {
    @GetMapping("/getUserCostInfo")
    public UserCostInfoVO getUserCostInfo(String queryType, String queryValue) {
        UserCostInfoVO res = new UserCostInfoVO();
        res.setAddr("北京市朝阳区");
        res.setCapitalNo("123456");
        res.setConsNo("1234567890");
        res.setConsName("张三");
        res.setConsType("居民");
        res.setPrepayAmt("0");
        res.setTotalOweAmt("10000");
        res.setTotalRcvblAmt("0");
        res.setTotalRcvedAmt("0");
        res.setTotalPenalty("0");
        res.setRecordCount("0");
        res.setRtnCode(ResponseCodeEnum.CODE_9999.getValue());
        res.setRtnMsg(ResponseCodeEnum.CODE_9999.getName());
        return res;
    }

    @GetMapping("/collect")
    public ResBaseVO collect(String bankSerial, String bankDate, String capitalNo, String payMode, String rcvAmt, String chargeCnt) {
        System.out.println("bankSerial:" + bankSerial + ", bankDate:" + bankDate + ", capitalNo:" + capitalNo + ", payMode:" + payMode+ ", rcvAmt:" + rcvAmt + ", chargeCnt:" + chargeCnt);
        ResBaseVO res = new ResBaseVO();
        res.setRtnCode(ResponseCodeEnum.CODE_9999.getValue());
        res.setRtnMsg(ResponseCodeEnum.CODE_9999.getName());
        return res;
    }

    @GetMapping("/queryPayment")
    public QueryCollectResVO queryPayment(String bankSerial, String bankDate, String acctOrgNo) {
        System.out.println("bankSerial:" + bankSerial + ", bankDate:" + bankDate + ", acctOrgNo:" + acctOrgNo);
        QueryCollectResVO res = new QueryCollectResVO();
        res.setRtnCode(ResponseCodeEnum.CODE_9999.getValue());
        res.setRtnMsg(ResponseCodeEnum.CODE_9999.getName());
        res.setInstSerial(bankSerial);
        return res;
    }

    @GetMapping("/noticeCheck")
    public ResBaseVO noticeCheck(String acctOrgNo, String filePath, String fileType, String fileName) {
        System.out.println("acctOrgNo:" + acctOrgNo + ", filePath:" + filePath + ", fileType:" + fileType + ", fileName:" + fileName);
        ResBaseVO res = new ResBaseVO();
        res.setRtnCode(ResponseCodeEnum.CODE_9999.getValue());
        res.setRtnMsg(ResponseCodeEnum.CODE_9999.getName());
        return res;
    }
}
